package com.msb.common.exception;

/**
 * @Author zhangjiajun
 * @Email zhangjiajun@hydsoft.com
 * @Description  错误编码和错误信息的枚举类
 * @Date 2025/6/19 9:29
 */

/**
 * 10：表示通用
 *
 * /001:参数格式错误 10001
 *
 * /002:未知异常 10002
 *
 * 11：商品
 *
 * 12：订单
 *
 * 13：物流
 *
 * 14：会员
 */
public enum BizCodeEnume {

    PRODUCT_UP_EXCEPTION(11001, "商品上架异常"),
    UNKNOW_EXCEPTION(10000, "未知异常"),
    VALID_EXCEPTION(10001, "参数格式异常"),
    VALUE_SMS_EXCEPTION(10002, "操作过于频繁,请稍后重试!"),
    USERNAME_EXIST_EXCEPTION(15001, "用户名存在"),
    PHONE_EXIST_EXCEPTION(15002, "手机号存在"),
    USERNAME_PHONE_VALID_EXCEPTION(15003, "账号或则密码错误");

    private int code;
    private String msg;

    BizCodeEnume(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }


}
